<?

#print_r($fields);

/*
echo '<div class="story-inline">';
foreach ($fields as $id => $field): 
	#$class = ($field->class == 'comment-count') ? 'meta' : $field->class; ?>
  <?php if (!empty($field->separator)): echo $field->separator; endif; ?> <div class="story-<?php print $field->class ?>"> <?php print $field->content; ?> </div>
   <?php  #if($i==2): echo '</div>'; 
   
   endforeach;
echo '</div>'; ?>*/ 

$comments_link = false;
$commt_n = $fields['comment_count']->content;
$node_url = url('node/'.$row->nid);

if($commt_n > 0 ) {
	if($commt_n == 1)
		$comments_link = '<a href="'.$node_url.'#comments">'.$commt_n.' '.t('Comment').'</a>';
	else
		$comments_link = '<a href="'.$node_url.'#comments">'.$commt_n.' '.t('Comments').'</a>';
} 


?>

<div class="story-inline">  
    
    
     <div class="story-field-img-fid"> <?=$fields['field_img_fid']->content?> </div>

      <div class="story-tid"><?=$fields['tid']->content?> </div> 
      <div class="story-title"><?=$fields['title']->content?></div>
      <div class="story-created"><?=$fields['created']->content?></div>
     <?php if($comments_link): ?> <div class="story-comments-link"><?=$comments_link?></div> <?php endif; ?>
      <div class="story-body"> <?=$fields['teaser']->content?></div>
   </div>
